class Room(object):

    def __init__(self, bounds):
        self.bounds = bounds

    @property
    def min_p(self):
        return self.bounds.min

    @property
    def min_x(self):
        return self.bounds.min.x

    @property
    def min_y(self):
        return self.bounds.min.y

    @property
    def max_p(self):
        return self.bounds.max

    @property
    def max_x(self):
        return self.bounds.max.x

    @property
    def max_y(self):
        return self.bounds.max.y

    @property
    def corners(self):
        yield self.min_x, self.min_y
        yield self.min_x, self.max_y - 1
        yield self.max_x - 1, self.min_y
        yield self.max_x - 1, self.max_y - 1

    @property
    def walls(self):
        for y in (self.min_y, self.max_y - 1):
            for x in xrange(self.min_x, self.max_x):
                yield x, y
        for x in (self.min_x, self.max_x - 1):
            for y in xrange(self.min_y + 1, self.max_y - 1):
                yield x, y

    @property
    def neighbors(self):
        for y in (self.min_y - 1, self.max_y):
            for x in xrange(self.min_x - 1, self.max_x + 1):
                yield x, y
        for x in (self.min_x - 1, self.max_x):
            for y in xrange(self.min_y, self.max_y):
                yield x, y
